package learnCollection;

public class Dog implements Comparable<Dog> {

	private String name;
	private String type;
	private int age;
	
	public Dog(String name, String type) {
		this.name = name;
		this.type = type;
	}
	
	public Dog(String name, String type, int age) {
		this.name = name;
		this.type = type;
		this.age = age;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getType() {
		return type;
	}

	public void setType(String type) {
		this.type = type;
	}
	
	public int getAge() {
		return age;
	}

	@Override
	public int compareTo(Dog o) {
		return this.name.compareTo(o.name);
	}
	
}
